package mytest;

/**
 * @author 兴趣使然黄小黄
 * @version 1.0
 * @date 2023/3/16 22:38
 *  * 继承 Thread, 重写 run
 */
public class MyThread01 extends Thread {

    @Override
    public void run() {
        while (true) {
            System.out.println("线程 thread01");
            try {
                Thread.sleep(1000);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
        }
    }
}
